import LadderData from "./LadderData";
import { PlayState } from "./LadderItemModel";
import { KingWXUtil } from "../Public/KingWXUtil";

/*
 * @Author: LCL 
 * @Date: 2019-03-08 20:36:30
 * @Desc: 游戏UI管理器
*/

const {ccclass, property} = cc._decorator;

@ccclass
export default class GameOverControl extends cc.Component {

    //当前分数
    @property(cc.Label)
    curScroeL: cc.Label = null;

    //历史分数
    @property(cc.Label)
    hisScroeL: cc.Label = null;

    // onLoad () {}

    start () {

    }

    public updateScroe(){
        this.curScroeL.string = ""+LadderData.getInstance().playerCtr.curIndex;
        this.hisScroeL.string = "历史最佳成绩："+0;

        KingWXUtil.getUserScore();
    }

    

    //home按钮
    public homeBtnClick(){
        LadderData.getInstance().uiCtr.gotoLogin();
    }

    //继续游戏按钮
    public goOnBtnClick(){
        LadderData.getInstance().uiCtr.goOnGame();
    }

    // update (dt) {}
}

/*
public void TEXT1() 
{
	int textNum = 1;
	if (textNum == 1) 
	{
		textNum = 2;
    }
}
public void TEXT2()
{
    int textNum = 1;
    if (textNum == 1)
    {
        textNum = 2;
    }
}
public void TEXT3()
{
    int textNum = 1;
    if (textNum == 1)
    {
        textNum = 2;
    }
}

public void TEXT4()
{
    int textNum = 1;
    if (textNum == 1)
    {
        textNum = 2;
    }
}

public void TEXT5()
{
    int textNum = 1;
    if (textNum == 1)
    {
        textNum = 2;
    }
}

public void TEXT6()
{
    int textNum = 1;
    if (textNum == 1)
    {
        textNum = 2;
    }
}

public void TEXT8()
{
    int textNum = 1;
    if (textNum == 1)
    {
        textNum = 2;
    }
}

public void TEXT9()
{
    int textNum = 1;
    if (textNum == 1)
    {
        textNum = 2;
    }
}

public void TEXT10()
{
    int textNum = 1;
    if (textNum == 1)
    {
        textNum = 2;
    }
}

public void TEXT11()
{
    int textNum = 1;
    if (textNum == 1)
    {
        textNum = 2;
    }
}

public void TEXT12()
{
    int textNum = 1;
    if (textNum == 1)
    {
        textNum = 2;
    }
}

public void TEXT13()
{
    int textNum = 1;
    if (textNum == 1)
    {
        textNum = 2;
    }
}

public void TEXT14()
{
    int textNum = 1;
    if (textNum == 1)
    {
        textNum = 2;
    }
}

public void TEXT15()
{
    int textNum = 1;
    if (textNum == 1)
    {
        textNum = 2;
    }
}

public void TEXT16()
{
    int textNum = 1;
    if (textNum == 1)
    {
        textNum = 2;
    }
}

public void TEXT17()
{
    int textNum = 1;
    if (textNum == 1)
    {
        textNum = 2;
    }
}
*/
